﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace CSharp.Study.Generic.Classes
{
    public abstract class BaseKM
    {
        public string Name { get; protected set; }
        public abstract string ShowMsg();
        public void Go()
        {
            var aa = this is KMA;
        }
    }

    public class KMA : BaseKM
    {
        public KMA()
        {
            Name = "KMA";
        }
        public override string ShowMsg()
        {
            return "KMA666";
        }
    }

    public class KMB : BaseKM
    {
        public KMB()
        {
            Name = "KMB";
        }
        public override string ShowMsg()
        {
            return "KMB666";
        }
    }
}
